#测试博客的详情页
from selenium.webdriver.common.by import By

from common.Utils import BlogDriver


class BlogDetail:
    url = ""
    driver = ""
    def __init__(self):
        self.url = "博客详情页网址"
        self.driver = BlogDriver.drievr
        self.driver.get(self.url)

#登录状态下，博客详情页的测试
    def DetailByLoginText(self):
        #检查标题
        self.driver.find_element(By.CSS_SELECTOR,"#博客详情页的标题")
        #检查时间
        self.driver.find_element(By.CSS_SELECTOR,"#博客详情页的时间")
        #检查内容
        self.driver.find_element(By.CSS_SELECTOR,"#博客详情页的内容")
        #给上一个屏幕截图
        BlogDriver.getScreeShot()